##
##  $Header: /pub/cvsroot/mydns/pkg/Makefile.am,v 1.3 2002/07/14 20:13:43 bboy Exp $
##

EXTRA_DIST	=	README mydns.spec.in
SEDFILE 		=	../version.sed

sedvars:
	if ! `test -f $(SEDFILE)`; then make -C .. sedfile; fi

spec: sedvars mydns.spec.in
	sed -f $(SEDFILE) mydns.spec.in > mydns.spec

clean:
	rm -f core core* *~ mydns.spec

release: rpm
	$(INSTALL) -m 0644 /usr/src/redhat/RPMS/i386/@PACKAGE_NAME@-@PACKAGE_VERSION@-*rpm @WEBROOT@/download

rpm: spec
	@if ! `test -f ../mydns-@PACKAGE_VERSION@.tar.gz`; then make -C .. dist; fi
	cp -f mydns.spec /usr/src/redhat/SPECS
	cp -f ../mydns-@PACKAGE_VERSION@.tar.gz /usr/src/redhat/SOURCES
	rpm -ba /usr/src/redhat/SPECS/mydns.spec
	cp -f /usr/src/redhat/RPMS/i386/mydns-@PACKAGE_VERSION@-*.rpm .

## vi:set ts=3:
